window.onload = () => {
    const fs = require("fs")
    let euro = document.querySelector("#european")
    let btn = document.querySelector(".btn")
    let list = fs.readFileSync("./list.txt").toString().split("\n")

    btn.onclick = () => {
        let rt = 0
        let r = 0
        let interval = setInterval(() => {
            r = Math.floor(Math.random() * list.length)
            euro.innerText = list[r]
            rt++;
            if (rt === 30) {
                clearInterval(interval)
            }
        }, 100)
    }
}
